#!/usr/bin/env python
# -*- coding: utf-8 -*-

import os
import logging
logging.basicConfig(level=logging.INFO)
import sys

alphas = []
digits = []

def toArrayStr( arr ):
	rst = ''
	for index ,item in enumerate(arr):
		temp = str(item)
		rst +=temp
		if index <(len(arr)-1):
			rst +=','
	return rst

while(1):
	beInput = raw_input('请输入数字或字母(输入 quit 退出)：')
	if 'quit' == beInput:
		logging.info("退出程序")
		sys.exit();
	elif beInput.isalpha():
		logging.info("输入的是字母："+beInput)
		alphas.append(beInput);
		logging.info("当前字母列表："+toArrayStr(alphas))
	elif beInput.isdigit():
		logging.info("输入的是数字："+beInput)
		digits.append(beInput)
		logging.info("当前数字列表："+toArrayStr(digits))
	else:
		pass






